package com.shuogesha.platform.feign;

import static com.shuogesha.common.web.mongo.SimplePage.cpn;

import java.io.UnsupportedEncodingException;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

import com.shuogesha.common.util.JsonResult;
import com.shuogesha.common.util.ResultCode;
import com.shuogesha.platform.client.AuthenticationFeignClient;
import com.shuogesha.platform.entity.Authentication;

@RestController
@RequestMapping("/api/authentication/")
public class AuthenticationFeignAct {
//	@RequestMapping(value = "/list")
//	public Object v_list(String name, Integer pageNo, Integer pageSize) throws UnsupportedEncodingException {
//		return authenticationFeignClient.list(name, cpn(pageNo), pageSize);
//	}
//
//	@RequestMapping(value = "/get")
//	public Object v_get(Long id) {
//		return authenticationFeignClient.get(id);
//	}
//
//	@RequestMapping(value = "/save", method = RequestMethod.POST)
//	public Object o_save(@RequestBody Authentication bean) {
//
//		return authenticationFeignClient.save(bean);
//	}
//
//	@RequestMapping(value = "/update", method = RequestMethod.POST)
//	public Object o_update(@RequestBody Authentication bean) {
//		return authenticationFeignClient.update(bean);
//	}
//
//	@RequestMapping(value = "/delete")
//	public Object o_delete(Long[] ids) {
//		return authenticationFeignClient.delete(ids);
//	}

//	@Autowired
//	public AuthenticationFeignClient authenticationFeignClient;
//	
//	@RequestMapping(value = "/login")
//	public Object login(String username, String password, String ip) {
//		return authenticationFeignClient.login(username, password, ip);
//	}
//	
//	@RequestMapping(value = "/removeById")
//	public Object removeById(String id) {
//		authenticationFeignClient.removeById(id);
//		return new JsonResult(ResultCode.SUCCESS, null);
//	}
//	
//	@RequestMapping(value = "/findById")
//	public Object findById(String id) {
//		return new JsonResult(ResultCode.SUCCESS, authenticationFeignClient.findById(id));
//	} 
	
}
